Remote module inclusion without @#6898
Merged
bentsherman merged 3 commits into251117-module-system-implementation-with-remote-inclusionfrom Mar 6, 2026
Conversation
Signed-off-by: jorgee <jorge.ejarque@seqera.io>
Signed-off-by: jorgee <jorge.ejarque@seqera.io>
2fa01e8
into
251117-module-system-implementation-with-remote-inclusion
18 of 19 checks passed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR removes the
@prefix from remote module references throughout the codebase. DSL include statements now usescope/nameformat instead of@scope/name. Local/built-in includes still require/,./,../, orplugin/prefixes to be unambiguous.Changes
Module reference format (
scope/name)ModuleReference.groovy: Removed optional@?fromMODULE_NAME_PATTERN;fullNameno longer includes@IncludeDef.groovy: Remote module detection changed fromstartsWith('@')to absence of local prefixes + validscope/namepattern validation viaModuleReference.parse()ModuleResolver.java(nf-lang): ReplacedstartsWith("@")withisRemoteModule(source)static helper that validates thescope/nameregex patternResolveIncludeVisitor.java(nf-lang):isRemoteModulenow delegates toModuleResolver.isRemoteModule()for consistent pattern validationPipelineSpec.groovy: Backward-compat: strips leading@when reading oldnextflow_spec.jsonentriesCmdModuleInstall,CmdModuleRemove,CmdModuleInfo,CmdModuleRun): removed'@' + args[0]prepending;args[0]passed directly toModuleReference.parse().checksum→.module-infoproperties fileModuleChecksum.groovy: RenamedCHECKSUM_FILEconstant toMODULE_INFO_FILE = ".module-info". The file format changed from a raw checksum string to a Java properties file with achecksum=<sha256>entry.save()merges into existing properties;load()reads thechecksumpropertyInstalledModule.groovy: Renamed fieldchecksumFile→moduleInfoFile; enum valueMISSING_CHECKSUM→NO_REMOTE_MODULEModuleStorage.groovy: Uses.module-infoas the marker file when scanningmodules/for installed modules; skips.module-infowhen creating bundlesModuleRegistryClient.groovy: SimplifiedencodeName(no longer strips@)Key Design Decisions
1. Folder
modules/scope/namewithout.module-info→ treated as "not a remote module"When the resolver encounters a directory that exists at
modules/scope/namebut has no.module-infofile, it means the folder was not installed vianextflow module install(e.g. a manually created or pre-existing local directory):nextflow run): warns and continues (same behaviour asMODIFIED)nextflow module install): fails with an error pointing to the existing folder and suggesting--forceto override2.
nextflow module listdoes not show folders without.module-infoModuleStorage.listInstalled()scans themodules/tree and only recognises directories that contain a.module-infofile. Folders without this marker are silently ignored. This means manually-createdmodules/scope/namedirectories are invisible to the module list command.3.
nextflow module publish scope/namecreates/updates.module-infowith the current checksumWhen publishing a module using a module reference (scope/name), the publish command creates or updates the
.module-infofile with the current directory checksum. This marks the directory as a registered remote module and sets the integrity baseline.Note for cherry-pick
Commit 3119155 contains only CLI changes (renaming subcommands) and is safe to cherry-pick to PR #6768.
Test plan
nextflow module install nf-core/fastqcinstalls tomodules/nf-core/fastqc/with.module-infocontainingchecksum=<sha256>nextflow module listshows only modules with.module-info; manual folders are not showninclude { FASTQC } from 'nf-core/fastqc'resolves correctlyinclude { FASTQC } from '@nf-core/fastqc'fails with a clear errornextflow module installon a folder without.module-infofails without--forcemake test module=nextflowpasses🤖 Generated with Claude Code